package com.yami.shop.bean.model.tudu;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import java.util.Date;

@Data
@TableName("gwc_shopping_cart")
public class ShoppingCart {

    @ApiModelProperty(value = "购物车id")
    private Integer shoppingId;

    @ApiModelProperty(value = "商品id(-1是组合商品)")
    private Integer commodityId;

    @ApiModelProperty(value = "用户id")
    private String userId;

    @ApiModelProperty(value = "商品类型1单品2组合")
    private Integer commodityType;

    @ApiModelProperty(value = "购买方式(1单品2组合3单品加组合)")
    private Integer mode;


    @ApiModelProperty(value = "组合id")
    private String combinationId;

    @ApiModelProperty(value = "购物车产品个数")
    private Integer basketCount;

    @ApiModelProperty(value = "创建时间")
    private Date creTime;

    @ApiModelProperty(value = "组合")
    @TableField(exist = false)
    private Combination combination;

    @ApiModelProperty(value = "组合的商品")
    @TableField(exist = false)
    private Commodity commodity;

}
